Multi-user search system with methodology for personalized search query autocomplete

ABSTRACT

A multi-user search system with methodology for personalized search query autocomplete. In one embodiment, for example, a method for personalized search query autocomplete includes receiving, from an end-user computing device of an authenticated user, a completion search query including a completion token; determining an identifier of an authorized document namespace the authenticated user is permitted to access; generating an index key including the authorized document namespace identifier as a prefix and the completion token as a suffix; accessing an index dictionary with the index key to identify and iterate over a plurality of prefixed index tokens until a stop condition is reached, each of the plurality of prefixed index tokens including the authorized document namespace identifier as a prefix and the each index token as a suffix, the completion token being a prefix of or matching the each index token; and for each prefixed index token of the plurality of prefixed index tokens, determining whether any documents identified in a postings list associated with the each prefixed index token satisfies the completion query, and returning filenames of any such documents satisfying the completion query in an answer to the completion query.

RELATED APPLICATIONS

This application claims priority to U.S. Provisional Patent ApplicationNo. 62/040,382, “Multi-User Search System With Methodologies ForPersonal Searching,” filed Aug. 21, 2014, the contents of which ishereby incorporated by reference in its entirety.

This application is related to the following applications: (1) U.S.patent application Ser. No. 14/555,140, “Multi-User Search System withMethodology for Instant Indexing,” filed on Nov. 26, 2014; and (2) U.S.patent application Ser. No. 14/555,180, “Multi-User Search System withMethodology for Bypassing Instant Indexing,” filed on Nov. 26, 2014.Both of these applications are hereby incorporated by reference in theirentirety, for all purposes.

TECHNICAL FIELD

The disclosed embodiments relate generally to information retrievalcomputer systems and, more particularly, to a multi-user search systemhaving a methodology for personalized search query autocomplete.

BACKGROUND

Computers are very powerful tools for searching for relevant informationamong a vast amount of information. Indexes are a common mechanism forefficiently identifying information of interest among a large corpus ofinformation using a computer. A typical index is an organized mapping ofkeywords to the documents of information from which the keywords wereextracted or derived. As an example, an index of the world's publicallyaccessible web pages may map words in the web pages to the subset of theweb pages that contain that word.

Between the actual physical index itself (e.g., the index data as storedon one or more computers) and the users of the system, a search systemis typically provided as a software cushion or layer. In essence, thesearch system shields the user from knowing or even caring aboutunderlying index details. Typically, all requests from users forinformation in the index are processed by the search system. Forexample, documents relevant to a user's request for information may beidentified by the search system using an index, all without userknowledge of the underlying index implementation. In this manner, thesearch system provides users access to relevant information withoutconcern to how the information is indexed or accessed. One well-knownsearch system for identifying relevant information among the world'spublically accessible web pages is the GOOGLE Internet search engineprovided by Google Inc. of Mountain View, Calif.

One function of a search system is answer to search queries (or just“queries” for short). A query may be defined as a logical expressionincluding a set of one or more search terms, and results in theidentification of a subset of indexed documents. Consider, for instance,the handling of a request for information from an Internet searchengine. In operation, this request is typically issued by a clientsystem as one or more Hyper Text Transfer Protocol or “HTTP” requestsfor retrieving particular search results (e.g., a list of all Internetweb pages containing the words “college” and “basketball”) from indexeson server computers. In response to this request, the search systemtypically returns a web page containing hyperlinks to those Internet webpages considered to be most relevant to the search terms “college” and“basketball”.

Internet search engines are well-suited for searching all the world'sinformation that is publically available on the Internet. Recently,however, users are beginning to amass a substantial amount of “personal”digital information that is not publically accessible on the Internet orindexed by an Internet search engine. Such information can include, forexample, personal digital photos, school, and work documents among otherpersonal and private digital information. In some instances, a user'spersonal digital information is shared with a defined group users. Forexample, an employee may share work documents with other colleagues or auser may share digital photos with friends and family.

One way users have recently begun storing and managing all theirpersonal digital information is by using a cloud data storage service.Such services allows users to upload and store their personal digitalinformation on server computers accessible on the Internet or othernetwork from their various end-user computing devices. In someinstances, the service may synchronize information between end-usercomputing devices and service server computers to facilitate user accessto information locally at the end-user computing devices. One well-knowncloud data storage service is the DROPBOX content management serviceprovided by Dropbox, Inc. of San Francisco, Calif.

Users of cloud data storage services would appreciate ways to search forand locate their personal digital information hosted by such services.Such personal digital information is typically not publically accessibleon the Internet. For this and other reasons, Internet search engines aregenerally not adequate to meet the search needs of these users.

The approaches described in this section are approaches that could bepursued, but not necessarily approaches that have been previouslyconceived or pursued. Therefore, unless otherwise indicated, it shouldnot be assumed that any of the approaches described in this sectionqualify as prior art merely by virtue of their inclusion in thissection.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram of a basic computing device in accordance withsome embodiments of the invention.

FIG. 2 is a block diagram of a basic software system for controlling theoperation of the computing device in accordance with some embodiments ofthe invention.

FIG. 3 is a block diagram of a client/server system including amulti-user search system in accordance with some embodiments of theinvention.

FIG. 4 is a block diagram of a serving system of a multi-user searchsystem in accordance with some embodiments of the invention.

FIG. 5 is a block diagram of an index shard of a sharded document indexin accordance with some embodiments of the invention.

FIG. 6 is a flow diagram illustrating a process for personal searchingperformed by a serving system of a multi-user search system inaccordance with some embodiments of the invention.

FIG. 7 is a flow diagram illustrating a process performed by a routingserver for determining an index server that stores an index shard thatindexes documents belonging to a given document namespace in accordancewith some embodiments of the invention.

FIG. 8 is a flow diagram illustrating a process performed by a queryprocessor at an index server for generating a personalized answer to anon-completion query in accordance with some embodiments of theinvention.

FIG. 9 is a flow diagram illustrating a process performed by a queryprocessor at an index server for generating a personalized answer to acompletion query in accordance with some embodiments of the invention.

DETAILED DESCRIPTION

In the following description, for the purposes of explanation, numerousspecific details are set forth in order to provide a thoroughunderstanding of the disclosed technologies. It will be apparent,however, that the disclosed technologies can be practiced without thesespecific details. In other instances, well-known structures and devicesare shown in block diagram form in order to avoid unnecessarilyobscuring the disclosed technologies. As to the flowcharts, a blockwithin the flowcharts may represent both a method step and an apparatuselement for performing the method step. Depending upon the requirementsof the particular implementation at hand, the corresponding apparatuselement may be configured in hardware, software, firmware orcombinations thereof.

It will also be understood that, although the terms “first”, “second”,etc. may be used herein to describe various elements, these elementsshould not be limited by these terms. These terms are only used todistinguish one element from another. For example, a first device couldbe termed a second device, and, similarly, a second device could betermed a first device, without departing from the scope of theinvention. The first device and the second device are both devices, butthey are not the same device.

The terminology used herein is for the purpose of describing particularimplementations only and is not intended to be limiting of the claims.As used in this description and the appended claims, the singular forms“a”, “an” and “the” are intended to include the plural forms as well,unless the context clearly indicates otherwise. It will also beunderstood that the term “and/or” as used herein refers to andencompasses any and all possible combinations of one or more of theassociated listed items. It will be further understood that the terms“includes,” “including,” “comprises,” and/or “comprising”, when used inthis specification, specify the presence of stated features, integers,steps, operations, elements, and/or components, but do not preclude thepresence or addition of one or more other features, integers, steps,operations, elements, components, and/or groups thereof.

The term “if” may be construed to mean “when” or “upon” or “in responseto determining” or “in response to detecting,” depending on the context.Similarly, the phrase “if it is determined” or “if [a stated conditionor event] is detected” may be construed to mean “upon determining” or“in response to determining” or “upon detecting [the stated condition orevent]” or “in response to detecting [the stated condition or event],”depending on the context.

Overview

A multi-user computer search system with a personalized search queryautocomplete feature for searching documents is disclosed. The documentsmay include, for instance, users' personal documents such as, forexample, documents associated with users' accounts held with cloud datastorage service.

Various embodiments of the invention, among other aspects, facilitateincremental full-text and filename searching of users' personaldocuments in a multi-user computer search system.

Various embodiments of the invention, among other aspects, effect animprovement in the technical field of information retrieval usingcomputers.

Various embodiments of the invention, among other aspects, improvemulti-user cloud data storage services provided by cloud data storageservice providers.

Various embodiments of the invention, among other aspects, improve thefunctioning of multi-user computer search systems.

According to an embodiment of the invention, a first method forpersonalized search query autocomplete performed in the multi-usercomputer search system includes: receiving, from an end-user computingdevice of an authenticated user, a completion search query including acompletion token; determining an identifier of an authorized documentnamespace the authenticated user is permitted to access; generating anindex key including the authorized document namespace identifier as aprefix and the completion token as a suffix; accessing an indexdictionary with the index key to identify and iterate over a pluralityof prefixed index tokens in a lexicographical order of the plurality ofprefixed index tokens until a stop condition is reached, each of theplurality of prefixed index tokens including the authorized documentnamespace identifier as a prefix and the each index token as a suffix,the completion token being a prefix of or matching the each index token;and for each prefixed index token of the plurality of prefixed indextokens, determining whether any documents identified in a postings listassociated with the each prefixed index token satisfies the completionquery, and returning filenames of any such documents satisfying thecompletion query in an answer to the completion query.

According to another embodiment of the invention, a second method forpersonalized search query autocomplete in the multi-user computer searchsystem includes: receiving, from an end-user computing device of anauthenticated user, a completion search query including a completiontoken; determining an identifier of an authorized document namespace theauthenticated user is permitted to access; generating an index keyincluding the authorized document namespace identifier as a prefix andthe completion token as a suffix; accessing an index dictionary with theindex key to identify and iterate over a plurality of prefixed indextokens according to a descending order of sizes of postings listsassociated with the plurality of prefixed index tokens until a stopcondition is reached, each of the plurality of prefixed index tokensincluding the authorized document namespace identifier as a prefix andthe each index token as a suffix, the completion token being a prefix ofor matching the each index token; and for each prefixed index token ofthe plurality of prefixed index tokens, determining whether anydocuments identified in a postings list associated with the eachprefixed index token satisfies the completion query, and returningfilenames of any such documents satisfying the completion query in ananswer to the completion query.

According to some embodiments of the invention, the index dictionaryincludes index tokens extracted from filenames of documents belonging toa plurality of document namespaces.

According to some embodiments of the invention, the stop condition isreached after a threshold number of document filenames are returned inan answer to the completion query.

According to some embodiments of the invention, the stop condition isreached after expiration of a query execution timer.

According to some embodiments of the invention, the stop condition isreached after identifying and iterating over a threshold number of indextokens of the plurality of index tokens.

According to some embodiments of the invention, the completion queryincludes at least one complete token.

In other aspects, the invention encompasses a computer system and acomputer-readable medium configured to carry out the foregoing steps.

Basic Computer System Hardware and Software

The disclosed technologies may be implemented on one or more computingdevices. Such a computing device may be implemented in various formsincluding, but not limited to, a client, a server computer, a networkdevice, a mobile device, a cell phone, a smart phone, a laptop computer,a desktop computer, a workstation computer, a personal digitalassistant, a blade server computer, a mainframe computer, and othertypes of computers. The computing device described below and itscomponents, including their connections, relationships, and functions,is meant to be exemplary only, and not meant to limit implementations ofthe disclosed technologies described in this specification. Othercomputing devices suitable for implementing the disclosed technologiesmay have different components, including components with differentconnections, relationships, and functions.

Basic Computing Device

Turning now to FIG. 1, it is a block diagram of a basic computing device100 suitable for implementing the disclosed technologies in accordancewith some embodiments of the invention. Computing device 100 includesbus 102 or other communication mechanism for addressing main memory 106and for transferring data between and among the various components ofdevice 100. Computing device 100 also includes hardware processor 104coupled with bus 102 for processing information. Hardware processor 104may be a general purpose microprocessor, a system on a chip (SoC), orother processor suitable for implementing the described technologies.

Main memory 106, such as a random access memory (RAM) or other dynamicstorage device, is coupled to bus 102 for storing information andinstructions to be executed by processor 104. Main memory 106 also maybe used for storing temporary variables or other intermediateinformation during execution of instructions to be executed by processor104. Such instructions, when stored in non-transitory storage mediaaccessible to processor 104, render computing device 100 into aspecial-purpose computing device that is customized to perform theoperations specified in the instructions.

Computing device 100 further includes read only memory (ROM) 108 orother static storage device coupled to bus 102 for storing staticinformation and instructions for processor 104.

Mass storage device 110 is coupled to bus 102 for persistently storinginformation and instructions on fixed or removable media, such asmagnetic, optical, solid-state, magnetic-optical, flash memory, or anyother available mass storage technology. The mass storage may be sharedon a network, or it may be dedicated mass storage. Typically, massstorage devices 110 (e.g., the main hard disk for the device) stores abody of program and data for directing operation of the computingdevice, including an operating system, user application programs, driverand other support files, as well as other data files of all sorts.

Computing device 100 may be coupled via bus 102 to display 112, such asa liquid crystal display (LCD) or other electronic visual display, fordisplaying information to a computer user. Display 112 may also be atouch-sensitive display for communicating touch gesture (e.g., finger orstylus) input to processor 104.

An input device 114, including alphanumeric and other keys, is coupledto bus 102 for communicating information and command selections toprocessor 104.

Another type of user input device is cursor control 116, such as amouse, a trackball, or cursor direction keys for communicating directioninformation and command selections to processor 104 and for controllingcursor movement on display 112. This input device typically has twodegrees of freedom in two axes, a first axis (e.g., x) and a second axis(e.g., y), that allows the device to specify positions in a plane.

Computing device 100 may implement the methods described herein usingcustomized hard-wired logic, one or more application-specific integratedcircuits (ASICs), one or more field-programmable gate arrays (FPGAs),firmware, or program logic which, in combination with the computingdevice, causes or programs computing device 100 to be a special-purposemachine.

Methods disclosed herein may also be performed by computing device 100in response to processor 104 executing one or more sequences of one ormore instructions contained in main memory 106. Such instructions may beread into main memory 106 from another storage medium, such as storagedevice 110. Execution of the sequences of instructions contained in mainmemory 106 causes processor 104 to perform the process steps describedherein. In alternative embodiments, hard-wired circuitry may be used inplace of or in combination with software instructions.

The term “storage media” as used herein refers to any non-transitorymedia that store data and/or instructions that cause a computing deviceto operate in a specific fashion. Such storage media may comprisenon-volatile media and/or volatile media. Non-volatile media includes,for example, optical disks, magnetic disks, or solid-state drives, suchas storage device 110. Volatile media includes dynamic memory, such asmain memory 106. Common forms of storage media include, for example, afloppy disk, a flexible disk, hard disk, solid-state drive, magnetictape, or any other magnetic data storage medium, a CD-ROM, any otheroptical data storage medium, any physical medium with patterns of holes,a RAM, a PROM, and EPROM, a FLASH-EPROM, NVRAM, any other memory chip orcartridge.

Storage media is distinct from but may be used in conjunction withtransmission media. Transmission media participates in transferringinformation between storage media. For example, transmission mediaincludes coaxial cables, copper wire and fiber optics, including thewires that comprise bus 102. Transmission media can also take the formof acoustic or light waves, such as those generated during radio-waveand infra-red data communications.

Various forms of media may be involved in carrying one or more sequencesof one or more instructions to processor 104 for execution. For example,the instructions may initially be carried on a magnetic disk orsolid-state drive of a remote computer. The remote computer can load theinstructions into its dynamic memory and send the instructions over atelephone line using a modem. A modem local to computing device 100 canreceive the data on the telephone line and use an infra-red transmitterto convert the data to an infra-red signal. An infra-red detector canreceive the data carried in the infra-red signal and appropriatecircuitry can place the data on bus 102. Bus 102 carries the data tomain memory 106, from which processor 104 retrieves and executes theinstructions. The instructions received by main memory 106 mayoptionally be stored on storage device 110 either before or afterexecution by processor 104.

Computing device 100 also includes communication interface 118 coupledto bus 102. Communication interface 118 provides a two-way datacommunication coupling to wired or wireless network link 120 that isconnected to local network 122 (e.g., Ethernet network, Wireless LocalArea Network, cellular phone network, Bluetooth wireless network, or thelike). Communication interface 118 sends and receives electrical,electromagnetic, or optical signals that carry digital data streamsrepresenting various types of information. For example, communicationinterface 118 may be a wired network interface card, a wireless networkinterface card with an integrated radio antenna, or a modem (e.g., ISDN,DSL, or cable modem).

Network link 120 typically provide data communication through one ormore networks to other data devices. For example, network link 120 mayprovide a connection through local network 122 to host computer 124 orto data equipment operated by Internet Service Provider (ISP) 126. ISP126 in turn provides data communication services through the world widepacket data communication network now commonly referred to as the“Internet” 128. Local network 122 and Internet 128 use electrical,electromagnetic or optical signals that carry digital data streams. Thesignals through the various networks and the signals on network link 120and through communication interface 118, which carry the digital data toand from computing device 100, are example forms of transmission media.

Computing device 100 can send messages and receive data, includingprogram code, through local network 122, Internet 128, ISP 126, networklink 120 and communication interface(s) 118. In the Internet example,server computer 130 might transmit a requested code for an applicationprogram through Internet 128, ISP 126, local network 122 andcommunication interface 118.

The received code may be executed by processor 104 as it is received,and/or stored in storage device 110, or other non-volatile storage forlater execution.

Basic Software System

Turning now to FIG. 2, it is a block diagram of a basic software system200 for controlling the operation of computing device 100 in accordancewith some embodiments of the invention. As shown, computer softwaresystem 200 is provided for directing the operation of computing device100. Software system 200, which is stored in system memory (RAM) 106 andon fixed storage (e.g., hard disk) 110, includes kernel or operatingsystem (OS) 210. OS 210 manages low-level aspects of computer operation,including managing execution of processes, memory allocation, file inputand output (I/O), and device I/O. One or more application programs 202(e.g., 202A, 202B, 202C . . . 202N) may be “loaded” (e.g., transferredfrom fixed storage 110 into memory 106) for execution by system 200. Insome instances, application programs 202 or other software intended foruse on device 100 may also be stored as a set of downloadablecomputer-executable instructions, for example, for downloading andinstallation from an Internet location (e.g., from a web server).

Software system 200 may include graphical user interface (GUI) 215, forreceiving user commands and data in a graphical (e.g., “point-and-click”or “touch gesture”) fashion. These inputs, in turn, may be acted upon bysystem 200 in accordance with instructions from operating system 210and/or application programs 202. GUI 215 also serves to display theresults of operation from OS 210 and application programs 202, whereuponthe user may supply additional inputs or terminate the session (e.g.,log off).

OS 210 can execute directly on the bare hardware (e.g., processor 104)of device 100. Alternatively, hypervisor or virtual machine monitor(VMM) 230 may be interposed between the bare hardware and OS 210. Inthis configuration, VMM 230 acts as a software “cushion” orvirtualization layer between OS 210 and the bare hardware of device 100.

VMM 230, if present, instantiates and runs virtual machine instances(“guest machines”). Each guest machine includes a “guest” operatingsystem, such as OS 210, and one or more application programs, such asapplication programs 202, designed to execute on the guest operatingsystem. VMM 230 presents the guest operating systems with a virtualoperating platform and manages the execution of the guest operatingsystems. In some instances, VMM 230 may allow a guest operating systemto run as through it is running on the bare hardware of device 100directly. In these instances, the same version of the guest operatingsystem configured to execute on the bare hardware directly may also beable to execute on VMM 230 without modification or reconfiguration. Inother words, VMM 230 may provide full hardware and CPU virtualization toa guest operating system in some instances. In other instances, a guestoperating system may be specially designed or configured to execute onVMM 230 for efficiency. In these instances, the guest operating systemis “aware” that it executes on a virtual machine monitor. In otherwords, VMM 230 may provide para-virtualization to a guest operatingsystem in some instances.

The above-described computer hardware and software are presented forpurpose of illustrating basic underlying computer components that may beemployed for implementing the disclosed technologies. The disclosedtechnologies, however, are not limited to any particular computingenvironment or computing device configuration. Instead, the disclosedtechnologies may be implemented in any type of system architecture orprocessing environment capable of supporting the disclosed technologiespresented in detail below.

Client/Server Multi-User Search System Components

Turning now to FIG. 3, it is a block diagram of a client/server system300 in accordance with some embodiments of the invention. Theclient/server system 300 includes one or more servers 320 (collectivelyreferred to herein as “multi-user search system 320”). Also,client/server system 300 includes one or more clients 310 connected toone or more servers 325 (collectively referred to herein as “servingsystem 325”) via network 330. Specifically, clients 310 comprise one ormore end-user computing devices 311 connected to one or more servers 326(collectively referred to herein as “search front-end 326”) using aconventional network. In an exemplary embodiment, end-user computingdevices 311 may themselves comprise a plurality of end-user personalcomputing devices such as the above-described device 100 that run aconventional operating system such as MICROSOFT WINDOWS (e.g. XP, VISTA,7, 8, etc.), MAC OS X, LINUX (e.g., UBUNTU, FEDORA, etc.), IOS, ANDROID,BLACKBERRY OS, and the like.

Serving system 325 and one or more other servers 321 (collectivelyreferred to herein as “build system 321”), which are part of theaforementioned DROPBOX content management service in an exemplaryembodiment, generally operate as one or more independent processes(e.g., independent of the clients), running under a server operatingsystem such as UNIX, LINUX, and the like. Build system 321 includestoken store 324, indexer server 323 (or just “indexer 323”), andtokenizer 322 (or just “tokenizer 322”). In addition to search front-end326, serving system 325 also includes query processor 327 and documentindex 328.

A server of multi-user search system 320, including a server of buildsystem 321 and a server of serving system 325, may be implemented as aserver computer (e.g., device 100 of FIG. 1) or as a virtual machineinstance depending on the requirements of the particular implementationat hand. Where a server of multi-user search system 320 is implementedas a virtual machine instance there still may be an underlying servercomputer that hosts (executes) the “virtual” server. However, there isnot necessarily a one-to-one correspondence between virtual servers andserver computers. For example, a server computer can host multiplevirtual servers.

As used in this description and the appended claims, the singular form“server” is intended to include the plural form as well unless thecontext clearly indicates otherwise. For example, a “server” ofmulti-user search system 320 may actually be implemented by multipleservers that are mirrors or replicas of each other for load balancing,failover, redundancy, high availability, and/or other purposes accordingto the requirements of the particular implementation at hand.

In operation, clients 310 send search queries 332 to search front-end326 and receive query answers 334 thereto from search front-end 326. Thequeries 332 may be received at search front-end 326 in network requestsand the answers 334 sent from search front-end 326 in network responsesto the network requests. The network requests and the network responsesmay be received/sent over network 330 in network data packets. In someembodiments of the invention, the network data packets are formatted inaccordance with the Internet Protocol (IP). The network requests and thenetwork responses may also be received/sent in accordance with anapplication layer networking protocol. In some embodiments, theapplication layer networking protocol is the Hyper Text TransferProtocol (HTTP) or the Secure Hyper Text Transfer Protocol (HTTPS). Forexample, query 332 may be received in one or more HTTP or HTTPS requestsand answer 334 sent in one or more HTTP or HTTPS responses thereto.

Network 330 may include a number of conventional wired or wirelessnetwork systems including, for instance, a cellular telephone network, aLocal Area Network (LAN), a Wide Area Network (WAN), the Internet, andthe like. Serving system 325 and build system 321, and the serversthereof, may also be interconnected by one or more IP networks and/orother suitable type of data communications network and may alsocommunicate with each other using HTTP and/or HTTPS and/or othersuitable application layer protocol.

A search query 332 may comprise a search expression. The syntax of thesearch expression may include a sequence of one or more query tokens,possibly related together by one or more Boolean operators (e.g., AND,OR, NOT, etc.). A token may be defined as a sequence of one or morecharacters. A character in a token may be encoded according to aconventional character encoding scheme (e.g., ASCII, UTF-8, and thelike)

A query token may be defined as a token that appears in a search query332. For example, consider the simple conjunctive query 332: [baguettefromage] (without the enclosing brackets). A document 340 satisfyingthis query 332 may contain both the token “baguette” and the token“fromage” without necessarily being next to each other in the document340 and without the token “baguette” necessarily appearing before thetoken “fromage” in the document 340. However, a document 340 thatcontains or is associated with the tokens “baguette” and “fromage” neareach other and with the token “baguette” before the token “fromage” maybe considered more relevant than other documents 340 satisfying thequery 332.

A query answer 334 to a search query 332 returned from search front-end326 to a client (e.g., end-user computing device 311A) may comprise alist search answer summaries ordered by relevance. Each such summary maycorrespond to a document 340 identified by query processor 327 indocument index 328 satisfying the search query 332. A search answersummary may include, for example, an identifier (e.g., a name, a title,etc.) of the corresponding document, a short description (e.g., asynopsis, abstract, extract, snippet, etc.) of the correspondingdocument, an interactive hyperlink (e.g., a Uniform Resource Locator(URL)) for downloading, viewing, or taking some other user action on thecorresponding document, and possibly other useful information about thecorresponding document 340 (e.g., a thumbnail image of the correspondingdocument). The list of summaries may be presented to a user of theend-user computing device, for example, on a web page in a web browserapplication executing on the end-user computing device or, for instance,in another graphical user interface of an application (e.g., a mobileapplication) executing on the end-user computing device.

Search queries 332 received at search front-end 326 may be processed byquery processor 327. Query processor 327 may consult document index 328to identify documents satisfying search queries 332. References to(e.g., hyperlinks to) documents identified by query processor 327satisfying search queries 332 may be returned in answers 334. Atechnique in some embodiments of the invention performed by queryprocessor 327 for processing queries 332 may be as described in greaterdetail below.

In some cases, a search query 332 is a “completion” search query 332. Acompletion search query 332 may be defined as a search query 332including a sequence of one or more query tokens one of which is notcomplete. For example, a completion search query 332 may be submitted tosearch front-end 326 from an end-user computing device (e.g., 311A) whenthe user of the end-user computing device is in the middle of (e.g., inthe process of) entering (e.g., by typing) one of the query tokens ofthe completion search query 332. In this case, an answer 334 to thecompletion query 332 may comprise a list of possible completions to thecompletion search query 332 that query processor 327 identifies indocument index 328 based on the completion query 332.

The query tokens in a completion query 332 which are complete arereferred to herein as “complete tokens”. A query token in the completionquery 332 which is not complete is referred to herein as a “completiontoken”. Thus, a completion query may also be defined as a query 332 thatincludes a completion token.

A completion query 332 may comprise just a single character or more thanone character. For example, in the completion query 332 [p] (withoutenclosing brackets), there may be no complete tokens and the token “p”may be a completion token. A completion query 332 may instead compriseone or more complete tokens. For example, in the completion query 332[private se] (without enclosing brackets), the token “private” may be acomplete token and the token “se” may be a completion token.

Typically, the last token in the sequence of tokens of a completionquery 332 (or the only token if there is only one token in the sequence)is a completion token. Often, this is because the user enters the tokensof the competition query 332 in the same order they appear in thesequence. However, a token other than the last token of a completionquery 332 can be a completion token. For example, the user may move theinput cursor at his or her end-user computing device (e.g., 311A) toedit a previously entered token. For example, the user may enter thequery 332 [solved two problems] (without enclosing brackets) at a firsttime. Later, the user may move the input cursor to replace the token“two” with “th” to generate the completion query [solved th problems].In this example completion query 332, the first token “solved” and thelast token “problems” may be the complete tokens and the second token“th” may be the completion token.

In some embodiments of the invention, a query 332 is designated as acompletion query 332 in a network request including query 332. Forexample, the network request may indicate that a query token of query332 is a completion token. Identification of the completion token may bemade by software executing at the user's end-user computing device(e.g., 311A). For example, the software may send the network requestincluding query 332 to search front-end 326 as the user is entering(e.g., with a physical keyboard or soft keyboard) the characters of atoken of query 332 into a search user interface presented at the user'send-user computing device. In doing so, the software may flag, mark,identify, or otherwise indicate in the network request (e.g., withmetadata) that the token the user is entering is a completion token. Insome embodiments of the invention, the software executing at the user'send-user computing device is JAVASCRIPT software or other web browserclient side scripting language software and the search user interface ispresented on a web page displayed in a window of the user's web browser.In some embodiments of the invention, the software executing at theuser's end-user computing device is a mobile application or otherdedicated software application that drives the search user interface atthe user's end-user computing device.

A possible completion to a completion search query 332 may be defined asa search query 332 that is satisfied by at least one document 340indexed by document index 328 and that completes the completion query332. For example, the search query 332 [solved two problems] (noenclosing brackets) satisfied by at least one document 340 indexed bydocument index 328 may be a possible completion to the completion searchquery 332 [solved two prob] (without enclosing brackets). The list ofpossible completions to the completion query 332 may be provided in theanswer 334 in addition to or instead of a list of search answersummaries of documents 340 that satisfy the completion query 332. Atechnique in some embodiments of the invention employed by queryprocessor 327 for processing completion queries 332 may be as describedin greater detail below.

A query 332 that is not a completion query 332 may sometimes be referredto herein as a “non-completion” query 332 to distinguish the query 332from a completion query 332. A non-completion query 332 may also bedefined as a query 332 that contains only complete tokens and does notcontain any completion tokens. When referring to a query 332 generally,reference may be made herein to “query 332” or “search query 332”without the preceding “completion” or “non-completion” qualifier. Unlessotherwise clearly apparent in context, description herein pertaining toqueries 332 generally pertains to both completion queries 332 andnon-completion queries 332.

A document 340 may be defined as a collection of digital informationthat contains text content (e.g., character data) and/or is associatedwith text content (e.g., textual metadata). As just some examples, aword processing document 340 often contains text context (e.g., theauthored words and sentences of the document), a spreadsheet document340 may contain text context in the form of words and numbers, and adigital image document 340 (e.g., a digital photograph) may contain textcontent in its header (e.g., in Exchangeable image file format (Exif)).In addition or alternatively, a digital image document 340 may beassociated with text content in the form of textual metadata tags orother text description of the image content. These are just someexamples of possible types of documents and other types of documents arewithin the scope of invention.

In some instances, a document 340 corresponds to a file having a filetype. Some types of files that can be documents include, but are notlimited to, image files (e.g., jpg, .tiff, .gif), music files (e.g.,.mp3, .aiff, .m4a. wav), movie files (e.g., .mov, .mp4, .m4v), wordprocessing files (e.g., .doc, .docx, .pages), presentation files (e.g.,.ppt, .pptx, .key), spreadsheet files (e.g., .xls., .xlsx, .numbers),web page files (e.g., .htm, .html), text files (e.g., .txt), and anyother type of file that contains and/or is associated with text.

A document 340 can be associated with text context that is descriptiveof the document content. This associated text content is sometimesreferred to as “textual metadata” for the document. For example, thefilename of a document 340 can be textual metadata for the document 340.As another example, textual metadata for a digital image document may beproduced by a computer analysis of the image (e.g., optical characterrecognition (OCR), facial recognition algorithms, etc.). Other forms oftextual metadata for a document 340 can include, for instance, textcontent about the document 340 obtained from a web page that referencesthe document 340 (e.g., by a hyperlink), mentions the document 340(e.g., in a social networking post), or discusses the document 340(e.g., in a blog and/or user comments post). For purposes of thisdescription, textual metadata for a document 340 may be considered to bepart of and contained (occurring) in the text content of the document340.

A document 340 may also have multiple versions, one of which isconsidered the current version. For example, a user may create and savea first version of a word processing document 340 using a wordprocessing program. Sometime later, the user may modify the firstversion of the document 340 and save a second version of the document340 containing the modifications. Alternatively, a document 340 may haveonly one version at a time which is considered the current version.

Document index 328 may comprise one or more dictionary and postingspairs. The dictionary of a pair may store index tokens, and may alsocomprise a pointer to a postings list in the postings of the pair foreach index token. For example, the pointer may be an address of alocation in volatile or non-volatile memory where the postings list isstored.

An index token may be defined as a token by which a document 340 isindexed in document index 328. In addition to index tokens, a dictionarymay store token attributes for an index token such as, for example, thedocument frequency of the token. Token attributes for index tokens maybe used by query processor 327 to improve query processing efficiencyand search result ranking.

A postings list for an index token may store a list of one or moredocument identifiers of one or more documents 340 in which the tokenoccurs, and may also store document-token attributes for a document 340identified in the postings list such as, for instance, the frequency ofthe token in the document 340, or the position(s) of the token withinthe document 340. Document-token attributes for documents 340 inpostings lists may also be used by query processor 327 to improve queryprocessing efficiency and search result ranking.

When processing a query 332, query processor 327 may locate index tokensin a dictionary of document index 328 based on the query tokens in thequery 332. For example, for a query 332 such as [solved two problems](without the enclosing brackets), query processor 327 may locate theindex tokens “solved”, “two”, and “problems” in the dictionary. Queryprocessor 327 may retrieve postings lists for located index tokens usingthe pointers associated with the located index tokens in the dictionary.For example, query processor 327 may retrieve (e.g., load into RAM) froma postings of document index 328 associated with the dictionary postingslists for the index tokens “solved”, “two”, and “problems”.

Query processor 327 may merge retrieved postings lists using a mergealgorithm to identify documents 340 that satisfy the query 332. Forexample, assume the postings list retrieved for the index token “solved”identifies documents D2 and D3, the postings list retrieved for theindex token “two” identifies document D2, and the postings listretrieved for the index token “problems” identifies documents D2 and D3.Query processor 327 may then merge these three postings lists accordingto a merge algorithm to identify document D2 as containing all of thelocated index tokens. Various different merge algorithms may be used formerging postings lists and the invention is not limited to anyparticular merge algorithm. For example, the merge algorithm may combinemultiple postings lists by interleaved advancing of pointers througheach of the multiple postings lists.

Query processor 327 is not limited to processing only simple conjunctivequeries 332 and query processor 327 may process more complex queries332. For example, query processor 327 may process the following exampletypes of queries 332: Query A: [(two or three) NOT problems], Query B:[two three problems], Query C: [(two three) problems], and Query D:[(two OR three) (problems OR solutions)]. In each of the foregoingexample queries 332 within enclosing brackets [ ], the enclosingbrackets [ ] are not part of the query. Query A is equivalent to thequery 332 [(two or three) AND NOT problems], Query B is equivalent tothe Boolean query 332 [two AND three AND problems], Query C equivalentto the Boolean query 332 [(two AND three) AND problems], and Query Dequivalent to the Boolean query 332 [(two OR three) AND (problems ORsolutions). In the foregoing example queries 332, AND OR NOT ( ) areBoolean operators.

In some embodiments of the invention, document index 328 is horizontallypartitioned (e.g., sharded) across a plurality of index severs ofserving system 325 in which each of the index servers stores a portion(e.g., a shard) of document index 328. Various different techniques maybe used to horizontally partition (e.g., shard) index 328 across theindex servers. In some embodiments of the invention, document index 328is sharded by “document namespace”.

A document namespace may be defined as a collection of one or moredocuments 340 under common access control. The common access control canbe based on explicit and/or implicit permissions specifying and/orindicating which user(s) and/or group(s) of users have access to thedocuments 340 in the document namespace and what access (e.g., one ormore of read access, write access, share access, preview access,download access, etc.) the user(s) and/or group(s) of users have on thedocuments 340 that belong to the document namespace. Explicitpermissions may come in the form of, for example, one or more accesscontrol lists (ACLs) and/or other data associated with the documentnamespace (or an identifier thereof) specifying and/or indicating whichuser(s) and/or group(s) of users have access to the documents 340 in thedocument namespace and what access the user(s) and/or group(s) have onthe documents 340 in the document namespace. One example of an implicitpermission may be: a user has access to all documents 340 in a documentnamespace associated with an account (or an identifier thereof) of theuser.

In an exemplary embodiment, a document namespace includes documents 340associated with a user's account held with a cloud data storage servicesuch as, for example, the aforementioned DROPBOX content managementservice. By successfully authenticating against the account (e.g., witha valid username/password), a user implicitly has access to thedocuments 340 in the document namespace associated with the user'saccount.

In an exemplary embodiment, a document namespace includes documents 340belonging to a collection of one or more documents 340 that is sharedamong multiple user accounts held with a cloud data storage service suchas, for example, the aforementioned DROPBOX content management service.In some instances, the collection of documents may be referred to as a“shared folder”. By successfully authenticating against an account withwhich the collection of documents is shared with, a user has access tothe documents in the shared document namespace.

According to some embodiments of the invention in which document index328 is sharded by document namespace, each of a plurality of indexservers of serving system 325 indexes documents 340 belonging to one ormore document namespaces. In some embodiments of the invention, anidentifier of a document namespace is used as the shard key to determinean index server that indexes documents 340 in the document namespace. Ina non-limiting exemplary embodiment, document index 328 indexesdocuments in over four-hundred million (400,000,000) documentnamespaces.

Documents 340 may include any document 340 that is provided or madeavailable for processing by build system 321 or that is indexed indocument index 328. Build system 321 constructs index database files 351of document index 328 from documents 340. Build system 321 alsogenerates index mutations 352 to document index 328 from documents 340.

An index database file 351 may comprise a dictionary and postings pairthat together index one or more documents 340. Very generally, the datawithin an index database file 351 may be structured as a collection ofkey-value pairs (e.g., an associative array) in which the keyscorrespond to the index tokens of the dictionary and the valuescorresponding to the postings lists of the postings. In some embodimentsof the invention, an index database file 351 indexes documents 340 inone document namespace. In some embodiments of the invention, to reducethe number of index database files 351 of document index 328, an indexdatabase file 351 indexes documents 340 in multiple document namespaces.The multiple document namespaces indexed by an index database file 351is sometimes referred to herein as a “document namespace group” ofdocument namespaces.

Constructing index database files 351 of document index 328 by buildsystem 321 may involve tokenizer 322 generating sets of tokens bytokenizing documents 340 and storing the generated sets of tokens intoken store 324. Indexer 323 may then generate index database files 351based on the generated sets of tokens. Indexer 323 provides generatedindex database files 351 to serving system 325 for storage on indexservers of serving system 325 as part of document index 328. A techniquein some embodiments of the invention implemented by build system 321 forconstructing index database files 351 of document index 328 fromdocuments 340 may be as described in U.S. patent application Ser. No.14/555,180, “Multi-User Search System with Methodology for BypassingInstant Indexing.”

Generating index mutations 352 to document index 328 from documents 340by build system 321 may involve tokenizer 322 notifying indexer 323after generating a set of tokens from a recently created or recentlymodified document 340. For example, the document 340 may have beenrecently created or recently modified by a user of an end-user computingdevice 311. When notified of a recently created document 340 or whennotified of an modified document 340, indexer 323 generates an indexmutation 352 for the document based on one or more sets of tokens storedfor the document in token store 324. In some instances such as, forinstance, when the document has been modified, the generated indexmutation 352 reflects the differences between the set of tokensgenerated for the modified document and a set of tokens generated for aprevious version of the document. The generated index mutation 352 maybe provided to serving system 325 which then applies it document index328. A technique in some embodiments of the invention implemented bybuild system 321 for generating index mutations 352 to document index328 from recently created and modified documents 340 may be as describedin U.S. patent application Ser. No. 14/555,140, “Multi-User SearchSystem with Methodology for Instant Indexing.”

Tokenizer 322 produces sets of tokens by tokenizing the text content ofdocuments 340. Tokenizing the text content of a document may includeobtaining a character sequence of the document. Various techniques maybe used by tokenizer 322 to obtain the character sequence of thedocument depending on the format of the document data. For example, thetechnique or techniques used may include decoding the document dependingon the character encoding scheme of the document (e.g., ASCII, UnicodeUTF-8, MICROSOFT WORD, ADOBE PDF, etc.) and/or uncompressing thedocument depending on whether the document is compressed (e.g., by ZIPcompression).

Once the character sequence of the document is obtained, tokenizer 322divides the character sequence into pieces, called tokens, possiblyperforming linguistic processing on tokens at the same time. Linguisticprocessing may include, for instance, ignoring certain characters (e.g.,punctuation), dropping common words (e.g., stop words), and/or stemmingand lemmatization. Linguistic processing may also include tokennormalization including removing diacritics and accents and/orcapitalization/case-folding, and the like.

After tokenizer 322 has generated a set of tokens for a document,tokenizer 322 stores the set of tokens in token store 324. In someinstances such as, for example, when tokenizer 322 notifies indexer 323of a recently created document 340 or notifies indexer 323 of a recentlymodified document 340, tokenizer 322 may also provide the set of tokensto indexer 323.

Token store 324 stores sets of tokens generated for documents 340 bytokenizer 322. For example, for a given version of a document 340, tokenstore 324 may store the set of tokens generated by tokenizer 322 forthat document version.

In some embodiments of the invention, token store 324 includes acolumn-oriented, distributed database system such as, for example, theAPACHE HBASE database system. However, other types of database systemsmay be used in other embodiments according to the requirements of theparticular implemented at hand. For example, a proprietary, arelational, or a stand-alone database system may be used instead of anopen source, a column-oriented, or a distributed one.

With the above exemplary client-server multi-user search system 320 inmind, the serving system 325 and components thereof used for processingqueries 332 and returning personalized answers 334 thereto will now bedescribed in greater detail.

Serving System Components

Turning now to FIG. 4, it is a block diagram illustrating components ofserving system 325 in greater detail in accordance with some embodimentsof the invention. Serving system 325 includes one or more servers 326(collectively referred to herein as “front-end servers 326”), one ormore servers 410 (collectively referred to herein as “access controlservers 410”), and query processor 327.

Query processor 327 is distributed over two-levels of servers: (1) oneor more servers 430 (collectively referred to as “index servers 430”)responsible for storing document index 328 and processing queries 332against index shards (e.g., 328A, 328B, 328C . . . 328N) of documentindex 328 and (2) one or more servers 430 (collectively referred to as“routing servers 420”) responsible for routing queries 332 fromfront-end servers 326 to the appropriate index servers 430 based ondocument namespace identifiers associated with the queries 332 andcombining answers 418 returned from index servers 430 into answers 334that are then returned to the front-end servers 326 and ultimately tothe end-user computing devices 311.

Each index shard (e.g., 328A, 328B, 328C . . . 328N) of document index328 may be stored at a corresponding index server (e.g., 430A, 430B,430C . . . 430N). An index shard (e.g., 328B) at an index server (430B)may index documents 340 in one or more document namespaces assigned tothe index shard.

In operation, front-end server 326A receives a search query 332A from anend-user computing device (e.g., 311A) and returns a personalized answer334A thereto back to the end-user computing device. The answer 334A maybe personalized in the sense that the documents 340 identified in theanswer 334 as relevant to the query 332A may be restricted to onlydocuments 340 that belong to a document namespace that the user isauthorized to access. If the query 332A is a completion query, then theanswer 334A may also be personalized in the sense that the possiblecompletions to the completion query included in the answer 334 may becomposed of only index tokens in document index 328 that index documents340 that belong to a document namespace the user is authorized toaccess. The user may be authenticated to facilitate the personalizationof the answer 334A.

As such, the query 332A may be received at front-end search 326A in thecontext of an authentication session established for an authenticateduser. For example, the authenticated user may be a user of the end-usercomputing device that sent query 332A to front-end server 326A. Theauthenticated user may have been authenticated prior to front-end server326A receiving query 332A. For example, the authenticated user may havebeen authenticated in response to receiving an authentication networkrequest from the end-user computing device that contained authenticationcredentials (e.g., a username/password pair). In response to receivingthe authentication network request, the password in the network requestmay be compared to a known password for the given username. If thepasswords match, then an authentication session is established.Otherwise, if the passwords do not match, then no authentication sessionis established.

Authentication credentials other than a username/password pair may beused to authenticate the user. For example, in some instances, the usermay be authenticated according to a multi-factor authenticationtechnique. For example, in addition to something that the user knows(e.g., a username/password pair), the user may be authenticated based onsomething the user has in his or her possession (e.g., a FOB or a mobilephone) and/or based on something the user is (e.g., a biometricmeasurement). In some instances, the user may be authenticated accordingto an authentication protocol that does not require the user to providea password. Some example authentication protocols suitable for thispurpose include the Open Authorization (OAuth), the OpenId, and theSecurity Assertion Markup Language (SAML) authentication protocols.

While in some instances, the user is authenticated prior to front-endserver 326A receiving query 332A, the user is authenticated in responseto receiving query 332A in other embodiments. For example, the networkrequest containing query 332A may also contain authenticationcredentials for authenticating the user, or the user can otherwise beauthenticated in response to receiving the network request containingthe query 332A.

After the user is authenticated, an authentication session may beestablished for the user in the form of a session identifier token. Inparticular, the session identifier token may be created in response tosuccessfully authenticating the user. After creation, the sessionidentifier token may be sent (e.g., in a “cookie”) between the user'send-user computing device and front-end server 326A in network requestsand network responses including in a network request containing query332A and in a network response containing answer 334A. The sessionidentifier token identifies, directly or indirectly (e.g., through anassociative array), a user account that the user successfullyauthenticated against (e.g., an account uniquely identified by ausername). The session identifier token may be cryptographicallyencrypted for extra security.

From time to time (e.g., in response to receiving query 332A) or over aperiod of time (e.g., from a time the user is authenticated until theanswer 334A is returned to the user's end user computing device),authentication session data 411 may be stored in volatile ornon-volatile memory of front-end server 326A. Authentication sessiondata 411 may include information pertaining to the authenticated usersuch as the authenticated user's username, user identifier, or otheruser account identifier and associated privileges, permissions, and/orauthorizations.

Serving system 325 is capable of restricting the answer 334A to thequery 332A to identifying only documents 340 indexed in document index328 that satisfy the query 332A and that belong to a document namespacethat the authenticated user is authorized to access. Serving system 325is able to do this restricting even though document index 328 may indexdocuments 340 that satisfy the query 332A but that belong to a documentnamespace that the authenticated user is not authorized to access.

To restrict the answer 334A to the query 332A, the front-end server 326Amay send a network request 412 to access control server 410A requestingidentifier(s) of document namespace(s) the authenticated user ispermitted to access. To facilitate this determination by access controlserver 410A, network request 412 may contain an indication or identifierof the authenticated user. For example, the indication or identifier canbe a username, a session identifier token, a user account identifier, orother information that uniquely identifies the user and/or the useraccount the user successfully authenticated against.

In response to receiving network request 412, access control server 410Acan lookup in a user account database (not shown in FIG. 4)identifier(s) of document namespace(s) the authenticated user ispermitted to access using as a key in the lookup operation theindication or identifier of the authenticated user provided in therequest 412.

Front-end server 326A may send network request 412 to access controlserver 410A at various different times, For example, front-end server426A may send network request 412 in response to receiving query 332A.As another example, front-end server 426A may send network request 412after successfully authenticating the user.

In response to receiving network request 412, access control server 410Areturns a network response 413 including identifier(s) of authorizeddocument namespace(s) the authenticated user is permitted to access.Each of the authorized document namespace identifiers uniquelyidentifies a document namespace the authenticated user is permitted toaccess at some access level according to explicit and/or implicit accesscontrols on the document namespace. For example, an authorized documentnamespace identifier may identify a document namespace for which theauthenticated user has at least read access to documents 340 belongingto the document namespace. For efficiency in processing subsequentnetwork requests, front-end server 326A may store (cache) authorizeddocument namespace identifier(s) as part of authentication session data411 maintained for the authenticated user. In this case, it may not benecessary for front-end server 326A to send network request 412 toaccess control server 410A in response to receiving query 332A.

The network request including query 332A from the user's end-usercomputing device may also specify identifier(s) of document namespace(s)that the user wishes to search. In this case, an intersection of the setof identifier(s) of document namespace(s) that the user wishes to searchand the set of identifier(s) of authorized document namespace(s) theuser is permitted to access may be computed to determine identifier(s)of authorized document namespace(s) to search. This intersection may beperformed by front-end server 326A. Alternatively, this intersection maybe performed by access control server 410A. In this case, front-endserver 326A may include identifier(s) of document namespace(s) that theuser wishes to search in the network request 412 and the networkresponse 413 thereto may include the result of the intersection ascomputed by access control server 410A.

If the network request including query 332A does not specific anyrequested document namespaces to search, then a default set ofidentifier(s) of authorized document namespace(s) to search may beselected. The selection of the default set can be performed by front-endserver 326A from the identifier(s) of authorized document namespace(s)returned in response 413 or cached as part of authentication sessiondata 411 as the case may be. Alternatively, access control server 410Amay select the default set from the set of all document namespaces theuser is permitted to access. In either case, the default set canidentify a) all document namespaces the user is permitted to access(e.g., all document namespaces associated with the authenticated user'saccount), or b) a subset thereof.

After the identifier(s) of authorized document namespace(s) to searchhave been determined, a network request including the query 332A and theidentifier(s) of authorized document namespace(s) to search may be sentfrom front-end server 326A to a routing server 420A for furtherprocessing of query 332A by query processor 327.

In response to receiving the network request from front-end server 326Aincluding the query 332A and the identifier(s) of the authorizeddocument namespace(s) to search, query processor 327 at routing server420A determines one or more index servers 430 to which to route thequery 332A. This determination may be made based on results of routingserver 420A applying deterministic mapping function 416 to each of theidentifier(s) of the authorized document namespace(s) to search. Thedeterministic mapping function 416 and index server mapping 417, givenan identifier of a document namespace, may be used by routing server(e.g., 420A) to determine an index server (e.g., 430B) that stores anindex shard (e.g., 328B) that indexes documents in the given documentnamespace.

According to some embodiments of the invention, deterministic mappingfunction 416 applies a one-way hash function, a simple hash function, aconsistent hash function, or the like to a document namespace identifierto search in order to determine an index shard (e.g., 328B) to which thedocument namespace is assigned. To make this determination, the queryprocessor 327 at routing server 420A may have access to index servermapping 417. Together, deterministic mapping function 416 and indexserver mapping 417 provide a way for query processor 327 at routingserver 420A to determine a hostname or a network address of an indexserver (e.g., 430B) at which an index shard (e.g., 328B) containing anindex for a given document namespace is stored.

In some embodiments of the invention, deterministic mapping function 416may include a hash mechanism and a modulo mechanism. Hash mechanism mayaccept a document namespace identifier as input (e.g., character stringdata representing the document namespace identifier) and may produce ahash value hv as output. For example, the hash mechanism may comprisethe MD4, MD5, SHA-1, or SHA2 message-digest algorithm which, whenapplied to a document namespace identifier provided as input, produces ahash value (e.g., a 32-bit hash value) as output. The modulo mechanismmay compute the remainder r of division of the hash value hv by amodulus k, thereby mapping the input document namespace identifier toone of k values in the range of 0 to k−1. The value of the modulus k maybe selected based on a variety of different factors including, forexample, the number of actual, expected, or desired index servers 430,the number of actual, expected, or desired document namespaces indexedby document index 328, and/or the number of actual, expected, or desireddocument namespaces groups. In one exemplary embodiment, the value k isa power of 2 and equals at least 1024.

In some embodiments of the invention, index server mapping 417 includesan entry for each of the index servers 430. Each such entry is keyed byone or more non-overlapping sub-ranges in the range 0 to k−1. Forexample, a first entry E1 in mapping 417 may have a key including thevalues K1 and K2 defining a first range of consecutive values in therange 0 to k−1 and a second entry E2 in mapping 417 may have a keyincluding the values K3 and K4 defining a second range of consecutivevalues in the range 0 to k−1 where the first range K1 to K2 does notoverlap the second range K3 to K4.

When query processor 327 at the routing server 420A appliesdeterministic mapping function 416 to a given document namespaceidentifier, a value r in the range 0 to k−1 may be produced. The queryprocessor 327 at the routing server 420A may then consult index servermapping 417 with the value r to identify the entry for which r is withinthe range of the entry key. A hostname or network address of this entrymay identify an index server (e.g., 430B) at which an index shard (e.g.,328B) that indexes documents 340 belonging to the given documentnamespace is stored.

In some embodiments of the invention, the document namespaces assignedto an index shard (e.g., 328B) are grouped into a fewer number ofdocument namespace groups of the index shard so as to reduce the numberof index files stored at the index server (e.g., 430B) at which theindex shard is stored. In other words, within an index shared (e.g.,328B), the document namespaces assigned to the index shard may bepartitioned into document namespace groups. Each such document namespacegroup may comprise multiple document namespaces.

For example, each of two million (2,000,000) document namespacesassigned to an index shard (e.g., 328B) may be partitioned into one ofeighty (80) document namespace groups of the index shard. Forefficiency, an index server (e.g., 430B) at which an index shard (e.g.,328B) is stored may store one or more index files for each of the eighty(80) document namespace groups instead of storing one or more indexfiles for each of the two million (2,000,000) document namespaces. Inthis case, the hash value hv output by the hash mechanism when appliedto a given document namespace identifier may be used as an identifier ofthe document namespace group to which the given document namespacebelongs.

In some embodiments, document namespace groups are not used to furtherpartition an index shard (e.g., 328B). In these embodiments, theremainder r of the division of the hash value hv by the modulus k may beused as the identifier of the index shard to which a given documentnamespace is assigned. Also in these embodiments, the index server atwhich the index shard is stored may store one or more index files forall document namespaces assigned to the index shard. For example, theindex server may store a single index file for all document namespacesassigned to the index shard.

Although, in FIG. 4, the index server mapping 417 is shown separatelyfrom the deterministic mapping function 416 and the query processor 327at the routing server 420A, the index server mapping 417 may be acomponent of the deterministic mapping function 416 or a component ofthe query processor 327 at routing server 420A. Further, each of therouting servers 420 may have access to the index server mapping 417. Inthis case, a copy of the index server mapping 417 may be stored (cached)at each of the routing servers 420 for efficient access. In addition oralternatively, the index server mapping 417 may be made available torouting servers 420 as a network service. Serving system 325 maycomprise multiple routing servers 420 scaled in a horizontal fashion forload balancing, increased capacity, increased throughput, reducedlatency, failover, and/or redundancy purposes.

In an exemplary embodiment, the document index 328 indexes documents 340in over four-hundred million (400,000,000) document namespaces and thedeterministic mapping function 416 and the index server mapping 417assign (map) each of the over 400 million document namespaces to one ofapproximately two hundred (200) index shards (e.g., 328A, 328B, 328C . .. 328N). In this exemplary embodiment, each index shard (e.g., 328A)indexes documents 340 in approximately two million (2,000,000) documentnamespaces.

In some instances, an index server (e.g., 430C) actually includes aplurality of servers distributed in a horizontal fashion to provide loadbalancing, failover, or redundancy for an index shard (e.g., 328C). Inthis case, each of the multiple index servers may store a replica or acopy of the index shard (e.g., 328C).

In some instances, an index server (e.g., 430A) includes multipleservers in which each of the multiple servers stores a portion of anindex shard (e.g., 328A). In this case, there may be multiple levels ofrouting servers. A first routing level is exemplified by the routingserver 420A that routes the query 332A received from the front-endserver 326A to one or more of the index servers 430. A second level ofrouting servers may exist to further route queries within an indexserver (e.g., 430C) to one or more of the multiple servers of the indexserver. In this case, the second level routing servers may also have adeterministic mapping function and mapping like deterministic mappingfunction 416 and index server mapping 417 for further routing thequeries based on identifiers of document namespaces.

In the example of FIG. 4, the query 332A is routed by the routing server420A according to the deterministic mapping function 416 and the indexserver mapping 417 to index servers 430B and 430C. However, the query332A could just as easily been routed to just a single index server 430or routed to more than two index servers 430, depending on the number ofauthorized document namespaces to search with the query 332A. Forexample, if there is only one authorized document namespace to search orif all of the authorized document namespaces to search are assigned tothe same index shard (e.g., 328B), then the query 332A may have beenrouted by routing server 420A to just one index server (e.g., 430B).

When routing the query 332A to an index server (e.g., 430B), the routingserver 420A may send a network request to the index server including thequery 332A. In addition, the network request may comprise identifier(s)of authorized document namespace(s) to search assigned to an index shard(e.g., 328B) stored at that index server. In addition, each suchauthorized document namespace identifier may be associated in thenetwork request with an identifier of the document namespace group towhich the document namespace belongs.

In some embodiments of the invention, the query processor 327 at anindex server (e.g., 430B) uses an identifier of a document namespacegroup in the network request received from the routing server 420A tolimit the portion of an index shard (e.g., 328B) that is accessed whendetermining an answer (e.g., 418A) to the query 332A. For example, thequery processor 327 at the index server may access only certain indexdatabase file(s) 351 stored in non-volatile memory at the index serveror only certain data structures stored in volatile memory of the indexserver based on the document namespace group identifiers in the networkrequest.

As an example, assume the network request including the query 332A sentfrom the front-end server 326A to the routing server 420A specifies thattwo authorized document namespaces are to be searched with correspondingdocument namespace identifiers “abcd” and “defg”. Further assume thataccording to the deterministic mapping function 416 and the index servermapping 417, authorized document namespace “abcd” belongs to documentnamespace group “1234” and is assigned to index shard 328B andauthorized document namespace “defg” belongs to document namespace group“5678” and is assigned to index shard 328C. In this case, the networkrequest from the routing server 420A to the index server 430B mayspecify that document namespace “abcd” in document namespace group“1234” is to be searched and the network request from routing server420A to index server 430C may specify that document namespace “defg” indocument namespace group “5678” is to be searched. Index server 430B mayuse the document namespace group identifier “1234” in the networkrequest sent to index server 430B to limit the portion of index shard328B accessed by query processor 327 at index server 430B whenformulating an answer 418A to the query 332A. Similarly, the indexserver 430C may use the document namespace group identifier “5678” inthe network request sent to index server 430C to limit the portion ofthe index shard 328C accessed by the query processor 327 at index server430C when formulating an answer 418B to the query 332A. Such limitingmay include, for example, accessing only index database file(s) 351stored in non-volatile memory of the index server and/or data involatile memory of the index server associated with a specified documentnamespace group identifier.

The routing server 420A may route the query 332A to multiple indexservers (e.g., 430B, 430C) so that the query processor 327 at each ofthe index servers 430 can process the query in parallel. For example,the routing server 420A may send a network request to index server 430Bincluding query 332A at the same or roughly the same time as routingserver 420A sends a network request to index server 430C including query332A. In this case, the query processor 327 at index server 430B mayprocess query 332A against index shard 328B at the same time or roughlythe same time as the query processor 327 at index server 430C processesquery 332A against index shard 328C.

When the query 332A is received at an index server (e.g., 430B), thequery processor 327 at the index server may consult (access) the indexshard (e.g., 328B) stored at the index server to determine documents 340that satisfy the query. In doing so, the query processor 327 at theindex server may restrict the documents 340 that can possibly beidentified in an answer (e.g., 418A) to the query to only documents 340that belong to an authorized document namespace to be searched. To dothis restriction, the query processor 327 at the index server may usethe authorized document namespace identifier(s) that accompanied thequery 332A in the network request from the routing server 420A. Inaddition, document identifiers of documents 340 indexed in the indexshard may be associated with the document namespace identifiers of thedocument namespaces to which the indexed documents 340 belong. Theseassociations facilitate query processor 327 restricting documents 340that can be identified in an answer to the query to those documents 1)that satisfy the query 332A and 2) that are associated with a documentnamespace identifier that is one of the authorized document namespaceidentifiers to be searched. Even if an indexed document 340 wouldotherwise satisfy the query, the query processor 327 at the index servermay not identify the document 340 in an answer 418A to the query 332 ifthe document 340 does not belong to one of the authorized documentnamespaces to search.

An answer (e.g., 418A) from an index server (e.g., 430B) returned to arouting server (e.g., 420A) may identify one or more documents 340 inone or more of the authorized document namespaces that satisfy the query332A. The documents may be ranked according to a ranking functionemployed by query processor 327 at the index server. The rankingfunction can be based on query-dependent metrics and/orquery-independent metrics computed for indexed documents.

An answer (e.g., 418A) from an index server (e.g., 430B) to the query332A may include a ranking score for each identified document generatedby the ranking function. The query processor 327 may employ the sameranking function at all of the index servers (e.g., 430A, 430B, 430C . .. 430N) so that ranking scores generated at different index servers forthe same query are comparable. Using the same ranking function at all ofthe index servers also allows query processor 327 at the routing server420A to combine documents 340 identified in the multiple answers 418Aand 418B to the query 332A returned from index servers 430B and 430Cinto a single answer 334A that is returned to the front-end server 326Aand ultimately to the end-user computing device 311A from which thequery 332A was received by the front-end server 326A.

According to some embodiments of the invention, the front-end server326A may apply a conventional spelling correction algorithm and/or aconventional phonetic correction algorithm (e.g., a soundex algorithm)to the obtained search query 332A. The spelling correction algorithm canapply different forms of spelling correction. For example, the spellingcorrection algorithm can apply a conventional isolated-term correctionalgorithm (e.g., edit distance and/or k-gram overlap) and/or aconventional context-sensitive correction algorithm. Accordingly, thequery 332A forwarded to routing server 420A and routed to index servers430 may reflect the results of spelling correction and/or phoneticcorrection performed on tokens of the query 332A by the front-end server326A.

Index Shard

Turning now to FIG. 5, it is a block diagram of an index shard (e.g.,328B) of document index 328 in accordance with some embodiments of theinvention. According to some embodiments of the invention, an indexshard may be structured as an inverted index including a dictionary 510and a corresponding postings 520.

Dictionary 510 may comprise index tokens (e.g., TOKEN 1, TOKEN 2, TOKEN3 . . . TOKEN N) by which documents 340 identified in postings 520 areindexed. Dictionary 510 also includes a pointer for each index token(e.g., TOKEN 1) to a postings list (e.g., POSTINGS LIST 2) of one ormore document identifiers (e.g., DOC ID 1) that identifies whichdocuments 340 the index token is indexed by (e.g., occurs in).

Dictionary 510 may also comprise information other than index tokenssuch as, for example, token attribute information such as, for example,token frequency information or other information that may be used by aranking function of query processor 327 to rank or otherwise determinethe relevancy of documents to a query in a query-dependent and/orquery-independent manner.

A postings list (e.g., POSTINGS LIST 2) of postings 520 may compriseinformation other than document identifiers such as, for example,document-token attribute information such as, for example, tokenfrequency of a token within a particular document 340, the position orpositions of a token within a particular document 340, or otherinformation that may be used by a ranking function of query processor327 to rank or otherwise determine the relevancy of documents 340 to aquery in a query-dependent and/or query-independent manner.

Document identifiers (e.g., DOC ID 1, DOC ID 2, DOC ID 3 . . . DOC ID N)in postings 520 may be associated with document namespace identifiers toindicate the document namespace to which the identified documents 340belongs. This association also allows query processor 327 at an indexserver (e.g., 430B) to restrict an answer (e.g., 417A) to a query (e.g.,332) to identifying only documents 340 that belong to an authorizeddocument namespace to be searched.

For example, an element in a postings list (e.g., POSTINGS LIST 2) maybe prefixed with a document namespace identifier that identifies thedocument namespace to which the document 340 belongs. For example, anelement in a postings list (e.g., POSTINGS LIST 2) may be characterstring data in the format <document namespace identifier>:<documentidentifier> where <document namespace identifier> is a character stringdata field identifying a document namespace and <document identifier> isa character string data field identifying a document 340 that belongs tothe document namespace. The colon ‘:’ character may be used as aseparator character to separate character string data fields within apostings list element. Other separator characters are possible. It alsopossible to not use a separator character where, for example, characterstring data fields have fixed lengths. Other formats for the documentidentifier are possible and the invention is not limited to anyparticular prefix format.

Instead of prefixing document identifiers in postings lists withdocument namespace identifiers to associate documents 340 with thedocument namespaces they belong to, an index shard may comprise amany-to-one mapping that maps a given document identifier to theidentifier of the document namespace to which the documents 340 belong.The mapping is many-to-one because a document namespace may containmultiple documents 340.

In some embodiments of the invention, for space efficiency and to reducethe size of postings 520, a document namespace identifier or a documentidentifier in a postings list (e.g., POSTINGS LIST 2) includes a localidentifier that is local to the index shard (e.g., index shard 328B) andsubstitutes for a global document namespace identifier or a globaldocument identifier that is larger in size (e.g., in terms of number ofbytes). The local identifier may be smaller in size (e.g., in terms ofnumber of bytes) than the global document namespace identifier or theglobal document identifier the local identifier substitutes for.

An index shard (e.g., 328B) may comprise a one-to-one mapping that mapsa given local identifier to a global document identifier. Alternatively,there may be two one-to-one mappings, one of the mappings fortranslating local document namespace identifiers to global documentnamespace identifiers and the other mapping for translating localdocument identifiers to global document identifiers. As yet anotheralternative, there may be a one-to-one mapping for translating a givenlocal document namespace identifier to the global document identifierand the global document namespace identifier of the document namespaceto which the document 340 belongs.

In this description, unless otherwise clearly apparent in context, a“document identifier” of a document 340 refers to all possible forms ofthe document identifier that directly or indirectly (e.g., through anassociative array) uniquely identifies the document 340 including alocal document identifier of the document 340 and a global documentidentifier of the document 340.

Similarly, in this description, unless otherwise clearly apparent incontext, a “document namespace identifier” of a document namespacerefers to all possible forms of the document namespace identifier thatdirectly or indirectly (e.g., through an associative array) uniquelyidentifies the document namespace including a local document namespaceidentifier of the document namespace and an global document namespaceidentifier of the document namespace.

According to some embodiments of the invention, when a query (e.g., 332)is received at an index server (e.g., 430B), query processor 327 at theindex server uses the query tokens in the query as keys into adictionary 510 to identify postings lists in a corresponding postings520. If there are multiple query tokens in the query, the correspondingpostings lists may be merged appropriately depending on how the querytokens are related together as a Boolean expression.

In some embodiments of the invention, query processor 327 at an indexserver restricts the documents 340 identified in the correspondingpostings lists that can be included in an answer (e.g., 417A) to thequery to only those documents 340 that belong to an authorized documentnamespace to be searched. Query processor 327 at the index server doesthis in some embodiments of the invention by comparing documentnamespace identifiers associated with document identifiers in thecorresponding postings lists to authorized document namespaceidentifiers associated with the query (e.g., included in the networkrequest that includes the query from a routing server (e.g., 420A)). Ifa document namespace identifier associated with a document identifier ofa document 340 that otherwise satisfies the query matches an authorizeddocument namespace identifier associated with the query, then thedocument 340 may be included in the answer to the query. However, if thedocument namespace identifier associated with the document identifierdoes not match an authorized document namespace identifier associatedwith the query, then the document 340 is not included in the answer tothe query even if the document otherwise satisfies the query. In thisway, query processor 327 at index servers 430 may restrict answers toqueries to only documents 340 belonging to authorized documentnamespaces associated with the queries to be searched.

In some embodiments of the invention, an index shard stores multipledictionary 510/postings 520 pairs. For example, an index shard may storea dictionary 510 and corresponding postings 520 for each of multipledocument namespaces assigned to the index shard or for each of multipledocument namespace groups assigned to the index shard.

In some embodiments of the invention, an index shard (e.g., 328B) may beorganized into separately identifiable sets of index database files 351and volatile memory data structures according to the identifiers of thedocument namespace groups assigned to the index shard. In this case,there may be a separate dictionary 510 or separate dictionaries 510 andcorresponding postings 520 for each document namespace group assigned tothe index shard. When a query (e.g., 332) is received at an index server(e.g., 430B), query processor 327 at the index server can use thedocument namespace group identifiers associated with the authorizeddocument namespace identifiers in the network request from the routingserver to determine which dictionary 510 or dictionaries 510 andcorresponding postings 520 to access.

In some embodiments of the invention, an index shard (e.g., 328B) may beorganized into separately identifiable sets of index database files andvolatile memory data structures according to the identifiers of thedocument namespaces assigned to the index shard. In this case, there maybe a separate dictionary 510 or separate dictionaries 510 andcorresponding postings 520 for each document namespace assigned to theindex shard. When a query (e.g., 332) is received at an index server(e.g., 430B), query processor 327 at the index server can use thedocument namespace identifiers in the network request from the routingserver to determine which dictionary 510 or dictionaries 510 andpostings 520 to access.

In some embodiments of the invention, an index shard stores separatedictionary 510/postings 520 pairs for processing different types ofqueries. For example, for a given document namespace or a given documentnamespace group associated to an index shard, the index shard may storea first dictionary 510/postings 520 pair for processing non-completionqueries and a second dictionary 510/postings 520 pair for processingcompletion queries. Storing separate dictionary 510/postings 520 pairsallows the structure and content of a dictionary 510 and thecorresponding postings 520 to be tailored for processing a certain typeof query. For example, a dictionary 510 for processing completionqueries may include only index tokens for filenames of documents asopposed index tokens for the full-text of the documents to reduce thesize of the dictionary in terms of bytes consumed when stored onnon-volatile memory (e.g., flash memory) or in volatile memory (e.g.,RAM) and thereby allow query processor 327 to more quickly processcompletion queries.

Query processor 327 at an index server (e.g., 430C) may load adictionary 510 (or a portion thereof) from non-volatile storage (e.g.,flash memory) into volatile memory (e.g., RAM) for more efficientaccess. A postings list (e.g., POSTINGS LIST 2) may be stored innon-volatile memory (e.g., in flash memory) of an index server (e.g.,430C) and/or cached in volatile memory (e.g., RAM) of the index serverfor more efficient access. Cached postings lists may be evicted fromvolatile memory of the index server according to a cache eviction policysuch as, for example, a least recently accessed policy. Query processor327 at an index server (e.g., 430B) may also cache in volatile memory apostings list that is generated as a result of a merge algorithmperformed on multiple posting lists retrieved from a postings 520. Bydoing so, query processor 327 at the index server may avoid having toperform the merge algorithm on the multiple postings lists at a latertime.

Continuing to refer to FIG. 5, according to some embodiments of theinvention, to facilitate processing of completion queries, index tokensin a dictionary 510 may be prefixed by document namespace identifiersand the prefixed index tokens may be sorted within the dictionary in alexicographical order of the prefixed index tokens. A dictionary 510configured in this way is referred to herein as a “completion”dictionary.

In some embodiments of the invention, the postings list associated witha prefixed index token may comprise document identifiers of documents340 that belong to the document namespace identified in the prefixedindex token. Thus, an index token may appear in a completion dictionarymore than once, once for each of multiple document namespaces, if thecompletion dictionary includes prefixed index tokens for more than onedocument namespace.

For example, a prefixed index token in a completion dictionary may havethe form <document namespace identifier>:<index token> where <documentnamespace identifier> is a character string data field identifying adocument namespace and <index token> is a character string data fieldincluding the characters of the index token. The colon ‘:’ character, orother character, nay be used as a separator character to separatecharacter string data fields within the prefixed index token. An exampleof a prefixed index token is [abcd:private] (without the enclosingbrackets) where “abcd” is the identifier of a document namespace and“private” is the index token.

By sorting prefixed index tokens within a completion dictionaryaccording to a lexicographical sorting of the prefixed index tokens, aquery processor 327 at an index server (e.g., 430B) can more efficientlyidentify possible completions to a completion token of a completionquery. In particular, as a result of the lexicographical sorting ofprefixed index tokens, index tokens in a completion dictionary thatbelong to the same document namespace and that share a prefix thatmatches the completion token may be stored (clustered) near each other(e.g., in consecutive or contiguous memory locations) when thecompletion dictionary is stored in non-volatile memory or volatilememory. Such clustering facilitates sequential memory access when thequery processor accesses the completion dictionary to determine possiblecompletions to a completion token and also reduces or eliminates randommemory access when the accessing the completion dictionary.

For example, index tokens “concession”, “conclude”, “conclusion”,“concrete”, and “concurrent” for document namespace “abcd” may be storednear each other in memory as prefixed index tokens “abcd:concession”,“abcd:conclude”, “abcd:conclusion”, “abcd:concrete”, and“abcd:concurrent”, respectively. When processing a completion querywith, for example, the completion token “con” and for which a particulardocument namespace having an identifier of, for example, “abcd” is anauthorized document namespace to search, the query processor maygenerate an index key of “abcd:con” for accessing a completiondictionary. Since the prefixed index tokens are stored near each otherin memory as a result of the lexicographical sorting, the queryprocessor can more efficiently identify the index tokens “concession”,“conclude”, “conclusion”, “concrete”, and “concurrent” as possiblecompletions for the completion token “con” in the document namespace“abcd” than if the prefixed index tokens were not stored near each otherin memory.

In addition to prefixed index tokens of a completion dictionary beingstored near each other in memory as a result of a lexicographicalsorting of the prefixed index tokens, the pointers (e.g., addresses) ofthe completion dictionary associated with the sorted prefixed indextokens to the storage locations of the corresponding postings lists mayalso be stored near each other in memory as a result of alexicographical sorting of the prefixed index tokens. In particular, apointer to a storage location of a postings list for a prefixed indextoken may be stored near the prefixed index token in memory. Forexample, the pointer and the prefixed index token may be stored in thesame memory block or same set of consecutive or contiguous memoryblocks. Thus, not only can the query processor, for example, moreefficiently identify the index tokens “concession”, “conclude”,“conclusion”, “concrete”, and “concurrent” as possible completions inthe document namespace “abcd” for the completion token “con”, the queryprocessor can also more efficiently identify the storage locations ofthe posting lists corresponding to those index tokens as a result of thelexicographical sorting.

In some embodiments of the invention, sorting prefixed index tokens of acompletion dictionary in a lexicographical order of the prefixed indextokens includes sorting a plurality of records (data structures) of thecompletion dictionary in which each such record includes a prefixedindex token and an associated pointer (e.g., address) to a volatile ornon-volatile memory location at which the postings list for the prefixedindex token is stored. The plurality of records may be sorted accordingto a lexicographical ordering of their prefixed index tokens. Then thesorted records may be stored in consecutive or contiguous blocks ofcomputer memory (e.g., volatile memory or non-volatile memory).

The following description presents method steps that may be implementedusing computer-executable instructions, for directing operation of oneor more computing devices under processor control. Thecomputer-executable instructions may be stored on a computer-readablemedium, such as CD, DVD, flash memory, or the like. Thecomputer-executable instructions may also be stored as a set ofdownloadable computer-executable instructions, for example, fordownloading and installation from an Internet location (e.g., Webserver).

While a certain order for the method steps may be implied by the figuresand the following description, it will be understood that, unless thecontext clearly indicates otherwise, the method steps may be performedin a different order than is shown and/or described. Further, unless thecontext clearly indicates otherwise, the method steps may be performedin parallel (concurrently) with one another.

Process for Personal Searching

FIG. 6 is a flow diagram illustrating a process 600 for personalsearching performed by a serving system 325 of a multi-user searchsystem 320 in accordance with some embodiments of the invention.

At step 602, a search query 332A is obtained by a front-end server 326Afrom an authenticated user's end-user computing device 311A as describedherein. The search query 332A can be a completion query or anon-completion query.

At step 604, the front-end server 326A determines one or moreidentifiers of one or more authorized document namespaces to search asdescribed herein. The front-end server 326A then forwards the query 332Aand the one or more identifiers of the one or more authorized documentnamespaces to search to a routing server 420A as described herein.

At step 606, the routing server 420A determines one or more indexservers 430 to which the query 332A should be routed to as describedherein. A process in some embodiments of the invention performed by therouting server 420A for determining which index server(s) 430 to routethe query 332A to may be as described herein and below with respect toFIG. 7.

At step 608, the routing server 420A routes the query 332A to each ofthe one or more index servers 430 determined at step 606 to route thequery 332A to as described herein.

At step 610, the query 332A is processed by the query processor 327 ateach of the index servers 430 to which the query 332A is routed to atstep 608 as described herein. As mentioned, the query 332A can acompletion query or a non-completion query. A process in someembodiments of the invention performed by the query processor 327 at anindex server (e.g., 430B) for generating a personalized answer (e.g.,418A) to the query 332A when the query 332A is a non-completion querymay be as described herein and below with respect to FIG. 8. A processin some embodiments of the invention performed by the query processor327 at an index server (e.g., 430B) for generating a personalized answer(e.g., 418A) to the query 332A when the query 332A is a completion querymay be as described herein and below with respect to FIG. 9.

At step 612, the routing server 420A receives a personalized answer(e.g., 418A) to the query 332A from each of the index servers 430 towhich the query 332A was routed to at step 608 as described herein. Ifthe query 332A was routed to multiple index servers 430 at step 608,then the routing server 420A may receive multiple correspondingpersonalized answers 418 at step 612.

If multiple personalized answers 418 are received by the routing server420A at step 612, then the routing server 420A at step 614 may combinethe multiple personalized answers into a single personalized answer 334Athat is then returned to the front-end server 326A as described herein.

At step 616, the front-end server 326A returns the personalized answer334A to the query 332 to the end-user computing device 311A from whichthe query 332A was received as described herein.

Deterministic Query Routing

FIG. 7 is a flow diagram illustrating a process 700 performed by therouting server 420A for determining an index server (e.g., 430B) thatstores an index shard (e.g., 328B) that indexes documents 340 belongingto a given document namespace according to some embodiments of theinvention.

At step 702, the routing server 420A obtains an identifier for eachauthorized document namespace to search as described herein. Forexample, the routing server 420A may obtain the identifier(s) in anetwork request received from the front-end server 326A that alsoincludes a query 332A

At step 704, a deterministic mapping function 416 of the routing server420A applies a hash algorithm (e.g., a message digest algorithm) to eachof the authorized document namespace identifiers to generate a hashvalue hv for each of the authorized document namespace identifiers asdescribed herein. Any number of different hash algorithms may be used.However, the hash algorithm used should be deterministic in the sensethat for a given authorized document namespace identifier the hashalgorithm consistently outputs the same hash value. Non-limitingexamples of some suitable hash algorithms that may be used at step 704include the MD4, MD5, SHA-1, and SHA2 message digest algorithms.

At step 706, for each authorized document namespace to search, thedeterministic mapping function 416 of the routing server 420A computesthe remainder r of the division of the hash value hv computed for theauthorized document namespace at step 704 by a modulus k as describedherein.

At step 708, for each authorized document namespace to search, thedeterministic mapping function 416 of the routing server 420A identifiesa mapping entry in mapping 417 where the remainder r computed for theauthorized document namespace at step 706 is within the range of theentry's key as described herein. As mentioned, an entry in mapping 417may comprise a key and a value. The entry's key may define a sub-rangeof consecutive values in the range 0 to k−1. The entry's value maycomprise a hostname and/or a network address of an index server (e.g.,430B). For example, the entry's value may comprise a hostname or networkaddress of the index server by which the routing server 420A cangenerate and send a network request to the index server including thequery 332A among other various other information.

At step 710, for each index server identified at step 708, the routingserver 420A routes the query 332A to the index server as describedherein.

Processing Non-Completion Queries

FIG. 8 is a flow diagram illustrating a process 800 performed by thequery processor 327 at an index server (e.g., 430B) for generating apersonalized answer (e.g., 418A) to a query 332A when the query 332A isa non-completion query in accordance with some embodiments of theinvention. The query 332A may be received from a routing server (e.g.,420A) in a network request. The network request may also include one ormore identifiers of one or more authorized document namespaces tosearch. In addition, each such authorized document namespace identifiermay be associated in the network request with an identifier of adocument namespace group to which the document namespace belongs.

At step 802, the query processor 327 at the index server determines oneor more indexes of an index shard (e.g., 320B) at the index server toaccess. Each such index may include a dictionary (e.g., 510) andcorresponding postings (e.g., 520) stored in non-volatile memory (e.g.,flash memory) of the index server in an index database file 351. Eachsuch index may also have a volatile memory component. For example, thedictionary of the index may be stored in volatile memory of the indexserver. In addition, various postings lists from the postings of theindex may be cached in volatile memory of the index server from time totime. The query processor 327 may evict cached postings lists fromvolatile memory according to a cache eviction policy (e.g. LRU).

According to some embodiments, the index database file 351 of an indexis treated as immutable and updates to the index are stored in volatilememory of the index server. The updates may include a new index token bywhich a document 340 is to be indexed in the index and an index token bywhich a document 340 is no longer to be indexed in the index. Morespecifically, a “delta” postings list for an index token in the indexstored in volatile memory at the index server may reflect updates to the“base” postings list for the index token stored in the index databasefile 351 of the index.

For example, assume an index database file 351 of an index at an indexserver (e.g., 430A) indexes a document D2 by the tokens “solved”, “two”and “problems”. In this case, the index database file 351 may comprisethree base postings lists, one for each of the index tokens “solved”,“two”, and “problems”. Next, assume document D2 is edited to replace“solved two problems” with “solved three problems”. Next, assume theindex server receives one or more index mutations 352 specifying thatdocument D2 is no longer to be indexed by the index token “two” but isnow to be indexed by index token “three”. To represent these mutations352, a delta postings list for the index token “two” may be stored involatile memory of the index server to represent (e.g., with a deletionbit vector) that document D2 is no longer indexed by the index token“two” and another delta postings list for the index token “three” may bestored in volatile memory of the index server to represent (e.g., byincluding an identifier of document D2 in the postings list) thatdocument D2 is indexed by index token “three”. To represent thesemutations 352, it is not necessary to modify the index database file351. When processing a query (e.g., 332A), the query processor 327 atthe index server may consult both the base postings list for a givenquery token in the index database file 351 (which may be cached in RAM)and a delta postings list for the given query token stored in volatilememory. The query processor 327 may merge (e.g., intersect) the deltapostings list and the base postings list to determine the documents thatsatisfy the given query token.

According to some embodiments, the query processor 327 at the indexserver determines at step 802 the index(es) to access based on thedocument namespace group identifier(s) in the network request from therouting server 420A. For example, the query processor 327 may determineto access certain index database file(s) 351 and/or certain datastructures in volatile memory (e.g., dictionaries, postings lists, etc.)based on the document namespace group identifiers in the network requestfrom the routing server 420A.

At step 804, for each index to access determined at step 802, postingslist(s) for the query token(s) in the query 332A are loaded from theindex. Such loading may include retrieving a postings list stored innon-volatile memory at the index server and storing the postings list involatile memory at the index server. In some cases, the postings listmay already be stored (cached) in volatile memory at the index server.In this case, there may be no need to retrieve the postings list fromnon-volatile memory at the index server.

At step 806, if multiple postings lists are loaded at step 804, then themultiple postings lists are merged accordingly to produce a single“results” postings list that may comprise one or more identifiers of oneor more documents that satisfy (match) the query 332A. Various differentalgorithms may be used to merge postings lists for the purpose ofdetermining documents that satisfy (match) a given query. Embodiments ofthe invention are not limited to any particular merge algorithm. If onlyone postings list was loaded at step 804, for example, because there isonly one query token in the query 332A, then that one loaded postingslist may be the results postings list.

At step 808, the query processor 327 at the index server rank-orders thedocuments in the results postings list matching the query 332A accordingto a ranking algorithm. The ranking algorithm may involve computing aranking score for each matching document with respect to the query 332A.Various different ranking algorithms may be used and embodiments of theinvention are not limited to any particular ranking algorithm. Forexample, the ranking algorithm may compute ranking scores based on onquery-dependent metrics and/or query-independent metrics for querytokens and matching documents.

At step 810, the query processor 327 at the index server generates apersonalized answer (e.g., 418A) to the query 332A and sends the answerin a network response to the routing server 420A. The personalizedanswer may identify only matching documents that belong to an authorizeddocument namespace to search. To facilitate this, each matching documentidentified in the results postings list may be associated with anidentifier of the document namespace to which the matching documentbelongs. The query processor 327 at the index server may compare thedocument namespace identifier for a matching document to the set ofauthorized document namespace identifier(s) included in the networkrequest from the routing server 420A to determine whether the documentshould be identified in the personalized answer. If, based on thiscomparison, a matching document belongs to an authorized documentnamespace, then the matching document may be identified in thepersonalized answer. Otherwise, the matching document may not beidentified in the personalized answer.

Processing Completion Queries

FIG. 9 is a flow diagram illustrating a process 900 performed by thequery processor 327 at an index server (e.g., 430B) for generating apersonalized answer (e.g., 418A) to a query 332A when the query 332A isa completion query in accordance with some embodiments of the invention.

The completion query 332A may be received from a routing server (e.g.,420A) in a network request. The network request may also include one ormore identifiers of one or more authorized document namespaces tosearch. In addition, each such authorized document namespace identifiermay be associated in the network request with an identifier of adocument namespace group to which the document namespace belongs. Inaddition, the network request may indicate or specify which query tokenof the completion query 332A is the completion token. Any other querytokens in the completion query 332A are considered complete tokens.

According to some embodiments of the invention, an index shard (e.g.,328B) at an index server (e.g., 430B) may comprise a “completion” indexfor each of the one or more document namespace groups assigned to theindex shard. Each such completion index may comprise a completiondictionary and corresponding postings that together index documents inthe one or more document namespaces that belong to the documentnamespace group of the completion index.

According to some embodiments of the invention, the query processor 327at an index server (e.g., 430A) accesses the completion index for adocument namespace group when processing a completion query 332A for anauthorized document namespace to search belonging to the documentnamespace group of the completion index.

According to some embodiments of the invention, a completion indexindexes only the filenames of documents. That is, the index tokens inthe completion dictionary are limited to tokens extracted from thefilenames of documents in the one or more document namespaces thatbelong to the document namespace group of the completion index. By doingthis, the size of the completion index may be smaller relative to afull-text index or other index for the document namespace group, therebyfacilitating more efficient processing of completion queries 332 by thequery processor 327 at the index server while at the same time stillproviding answers 418 that are relevant to the completion queries 332.

As mentioned, a completion dictionary includes prefixed index tokenssorted in a lexicographical sort order. Each such prefixed index tokenincludes an index token prefixes with a document namespace identifier.The sorted prefixed index tokens may be stored (clustered) near eachother in the sorted order in volatile and/or non-volatile memory. Bydoing so, iterating over the prefixed index tokens in the sort order mayfacilitate sequential memory access during the iterating and reducerandom memory access during the iterating, thereby making it moreefficient for the query processor 327 at the index server to iterateover a set of prefixed index tokens in the completion dictionary thatshare a common prefix.

Turning now to FIG. 9, at step 902, the query processor 327 at the indexserver generates index keys for the query tokens of the completion query332A for use in accessing one or more completion dictionaries. Ingeneral, the index key is generated by prefixing the query token with anauthorized document namespace identifier in a form that matches the formof the prefixed index tokens in the completion dictionary. For example,if the form of prefixed index tokens in the completion dictionary is<document namespace identifier>:<index token> than the form of generatedindex keys may be <authorized document namespace identifier>:<querytoken>.

At step 902, the query processor 327 at the index server may generatemultiple index keys for each query token, one for each of multipleauthorized document namespaces to search, where each such authorizeddocument namespace to search is assigned to an index shard of the indexserver.

Steps 904-916 may be performed by the query processor 327 at the indexserver for each authorized document namespace to search specified in thenetwork request from the routing server 420A.

At step 904, for a given authorized document namespace to search, anyindex key(s) generated at step 902 for any complete token(s) of thecompletion query 332A are used to access the completion dictionary forthe document namespace group to which the given authorized documentnamespace belongs. In particular, the postings lists(s) associated withthe index key(s) are loaded for the complete token(s) in the completionquery 332A.

At step 906, for the given authorized document namespace to search, anypostings lists(s) loaded for the complete token(s) at step 904 aremerged to produce a “results” postings list for the complete token(s) inthe completion query 332A.

In addition to steps 908-916 being performed for each authorizeddocument namespace to search specified in the network request from therouting server 420A, steps 908-916 may be performed for each of multiplepossible completion tokens identified in the completion dictionary aspossible completions to the completion token in the completion query332A.

Steps 908-916 performed for an authorized document namespace generallyinvolves accessing the completion dictionary with the index keygenerated for the completion token and iterating over a plurality ofprefixed index tokens in a lexicographical order of the plurality ofprefixed index tokens until a stop condition is reached. Each of theplurality of prefixed index tokens that are iterated over for theauthorized document namespace may comprise an identifier of theauthorized document namespace as a prefix, the index token as a suffix,and with the completion token being a prefix of or matching the indextoken. Also during the iterating, for each prefixed index token of theplurality of prefixed index tokens, a determination is made whether anydocuments identified in a postings list associated with the prefixedindex token satisfies the completion query. Information for a documentin the postings list that does satisfy the completion query may bereturned in an answer to the completion query. In some embodiments, aprefixed index token is from a filename of a document and theinformation returned in an answer to a completion query for the documentis the document's filename.

In some embodiments of the invention, instead of iterating over theplurality of prefixed in tokens in a lexicographical order of theprefixed index tokens, prefixed index tokens are iterated over indecreasing order of the corresponding postings lists sizes, where thesize of a postings list is determined by the number of documentsidentified in the postings list. By iterating over prefixed index tokensin this order, the possible completions to the completion token by whichthe most documents are indexed are considered for inclusion in an answerto the completion query first.

To facilitate this iteration, an auxiliary per-namespace token-frequencymapping may be maintained at the index server. Each entry in the mappingincludes a key and a corresponding value. Each such key includes anindex token and each such value includes the size of the postings listin the completion dictionary for the index token and the documentnamespace. The entries of the auxiliary mapping may be sorted in themapping in a lexicographic order of the index tokens of the entry keysand the entries may be stored in their sorted order (clustered) incontiguous volatile and/or non-volatile memory locations. This allowsthe query processor 327 at the index server to more efficiently identifyall index tokens in the auxiliary mapping that share a common prefixthat matches the completion token in the completion query 332A. Once allsuch index tokens are identified, they are sorted in descending order oftheir postings lists sizes as specified by the entry values in auxiliarymapping. The resulting sorted order of the index tokens is the iterationorder for the index tokens when accessing the completion dictionary andconsidering possible completions to the completion token. Because theauxiliary mapping does not store the actual postings lists for indextokens, the auxiliary mapping may be much smaller in size in terms ofbytes that that the completion index. As a result, the iteration orderfor the index tokens can be determined from the auxiliary mapping withfewer memory I/O operations that if the iteration order was determinedfrom the completion index itself.

At step 908, the query processor 327 determines the next index token inthe iteration order that is a possible completion to the completiontoken. As just discussed, the iteration order can be based on alexicographical ordering of index tokens that share a common prefix thatmatches the completion token or based on a descending order of postinglists sizes for the index tokens.

At step 910, the query processor 327 loads the postings list for thecurrent possible completion token to the completion token in the query332A determined at step 908 in the iteration. In some cases, thepostings list for the current possible completion token may already bestored in volatile memory at the index server. In this case, it may notbe necessary to retrieve the postings list from non-volatile memory.

At step 912, if there were any complete token(s) in the completion query332A, then the results postings list for the complete token(s)determined at step 906 is merged with the postings list for the currentpossible completion token to the completion token determined at step 910in the iteration. This current “results” postings list for thecompletion query 332A resulting from this merge may comprise identifiersof one or more documents in the authorized document namespace thatsatisfy the completion query 332A where the completion token is replacedwith the current possible completion token. If there were not anycomplete tokens in the completion query 332A, then the current resultspostings list for the completion query 332A may be the postings listloaded for the current possible completion token at step 910 in theiteration.

At step 914, if the current results postings list for the completionquery 332A is non-empty (i.e., it identifies at least one document inthe authorized document namespace), then information for each documentidentified in the current results postings list for the completion query332A may be sent in an answer (e.g., 418A) to the completion query 332A.In some embodiments, this information includes the filename of thedocument.

While in some embodiments, the filename of the document is returned inan answer (e.g., 418A) to a completion query 332A, the completion query332A with the completion token replaced with the current possiblecompletion token is returned in an answer (e.g., 418A) to a completionquery 332A if the current results postings list for the completion query332A is non-empty. In either case, information returned in an answer(e.g., 418A) to a completion query 332A may be ultimately presented atthe end-user's computing device for selection by the user and forsubmission to the serving system 325 as another query 332A.

At step 916, the query processor 327 at the index server determineswhether to continue the iteration over possible completion tokens to thecompletion token in the completion query 332A. According to someembodiments, the query processor 327 stops the iteration if a stopcondition has been reached. According to some embodiments, the stopcondition is reached when any of the following conditions becomes true:

-   -   A threshold number of documents satisfying the completion query        332A with the completion token in the completion query 332A        substituted with a possible completion token have been        identified,    -   A threshold number of possible completion tokens have been        considered, or    -   A query execution timer has elapsed.

If, at step 916, it is determined that the stop condition has beenreached, then the iteration over possible completion tokens to thecompletion token in the completion query 332A ends. Otherwise, theiteration continues again at step 908 with the next possible completiontoken.

The above process for processing completion queries provides a number ofbenefits to end-users. For one, the process may reduce the time takenfor a user to receive an answer identifying a document of interest. Foranother, the process may reduce the number of keystrokes that a userneeds to enter into a search field to find a document of interest. Foryet another reason, the process may save the user the burden ofremembering the correct spelling of a token.

While in some embodiments the above process provides personalized searchquery auto-completion for document filenames, the above process providespersonalized search query auto-completion for document contents in otherembodiments.

Extensions and Alternatives

While the invention is described in some detail with specific referenceto a single-preferred embodiment and certain alternatives, there is nointent to limit the invention to that particular embodiment or thosespecific alternatives. Therefore, those skilled in the art willappreciate that modifications may be made to the preferred embodimentwithout departing from the teachings of the invention.

The invention claimed is:
 1. In a multi-user computer system, a methodfor personalized search query autocomplete comprising: receiving, froman end-user computing device of an authenticated user, a completionsearch query comprising a completion token; determining an identifier ofan authorized document namespace the authenticated user is permitted toaccess; generating an index key comprising the authorized documentnamespace identifier as a prefix and the completion token as a suffix;accessing an index dictionary with the index key to identify and iterateover a plurality of prefixed index tokens in a lexicographical order ofthe plurality of prefixed index tokens until a stop condition isreached, each of the plurality of prefixed index tokens comprising theauthorized document namespace identifier as a prefix and the each indextoken as a suffix, the completion token being a prefix of or matchingthe each index token; and for each prefixed index token of the pluralityof prefixed index tokens, determining whether any documents identifiedin a postings list associated with the each prefixed index tokensatisfies the completion query, and returning filenames of any suchdocuments satisfying the completion query in an answer to the completionquery.
 2. The method of claim 1, wherein the index dictionary comprisesindex tokens extracted from filenames of documents belonging to aplurality of document namespaces.
 3. The method of claim 1, wherein thestop condition is reached after a threshold number of document filenamesare returned in an answer to the completion query.
 4. The method ofclaim 1, wherein the stop condition is reached after expiration of aquery execution timer.
 5. The method of claim 1, wherein the stopcondition is reached after identifying and iterating over a thresholdnumber of index tokens of the plurality of index tokens in thelexicographical order.
 6. The method of claim 1, wherein the completionquery comprises at least one complete token.
 7. In a multi-user computersystem, a method for personalized search query autocomplete comprising:receiving, from an end-user computing device of an authenticated user, acompletion search query comprising a completion token; determining anidentifier of an authorized document namespace the authenticated user ispermitted to access; generating an index key comprising the authorizeddocument namespace identifier as a prefix and the completion token as asuffix; accessing an index dictionary with the index key to identify anditerate over a plurality of prefixed index tokens according to adescending order of sizes of postings lists associated with theplurality of prefixed index tokens until a stop condition is reached,each of the plurality of prefixed index tokens comprising the authorizeddocument namespace identifier as a prefix and the each index token as asuffix, the completion token being a prefix of or matching the eachindex token; and for each prefixed index token of the plurality ofprefixed index tokens, determining whether any documents identified in apostings list associated with the each prefixed index token satisfiesthe completion query, and returning filenames of any such documentssatisfying the completion query in an answer to the completion query. 8.The method of claim 7, wherein the index dictionary comprises indextokens extracted from filenames of documents belonging to a plurality ofdocument namespaces.
 9. The method of claim 7, wherein the stopcondition is reached after a threshold number of document filenames arereturned in an answer to the completion query.
 10. The method of claim7, wherein the stop condition is reached after expiration of a queryexecution timer.
 11. The method of claim 7, wherein the stop conditionis reached after identifying and iterating over a threshold number ofindex tokens of the plurality of index tokens.
 12. The method of claim7, wherein the completion query comprises at least one complete token.13. One or more non-transitory computer-readable media storing one ormore programs for execution by one or more processors, the one or moreprograms comprising instructions configured for: receiving, from anend-user computing device of an authenticated user, a completion searchquery comprising a completion token; determining an identifier of anauthorized document namespace the authenticated user is permitted toaccess; generating an index key comprising the authorized documentnamespace identifier as a prefix and the completion token as a suffix;accessing an index dictionary with the index key to identify and iterateover a plurality of prefixed index tokens in a lexicographical order ofthe plurality of prefixed index tokens until a stop condition isreached, each of the plurality of prefixed index tokens comprising theauthorized document namespace identifier as a prefix and the each indextoken as a suffix, the completion token being a prefix of or matchingthe each index token; and for each prefixed index token of the pluralityof prefixed index tokens, determining whether any documents identifiedin a postings list associated with the each prefixed index tokensatisfies the completion query, and returning filenames of any suchdocuments satisfying the completion query in an answer to the completionquery.
 14. The one or more non-transitory computer-readable media ofclaim 13, wherein the index dictionary comprises index tokens extractedfrom filenames of documents belonging to a plurality of documentnamespaces.
 15. The one or more non-transitory computer-readable mediaof claim 13, wherein the stop condition is reached after a thresholdnumber of document filenames are returned in an answer to the completionquery.
 16. The one or more non-transitory computer-readable media ofclaim 13, wherein the stop condition is reached after expiration of aquery execution timer.
 17. The one or more non-transitorycomputer-readable media of claim 13, wherein the stop condition isreached after identifying and iterating over a threshold number of indextokens of the plurality of index tokens in the lexicographical order.18. The one or more non-transitory computer-readable media of claim 13,wherein the completion query comprises at least one complete token. 19.A multi-user computing system comprising: one or more processors;storage media; one or more programs stored in the storage media andconfigured for execution by the one or more processors, the one or moreprograms comprising instructions configured for: receiving, from anend-user computing device of an authenticated user, a completion searchquery comprising a completion token; determining an identifier of anauthorized document namespace the authenticated user is permitted toaccess; generating an index key comprising the authorized documentnamespace identifier as a prefix and the completion token as a suffix;accessing an index dictionary with the index key to identify and iterateover a plurality of prefixed index tokens according to a descendingorder of sizes of postings lists associated with the plurality ofprefixed index tokens until a stop condition is reached, each of theplurality of prefixed index tokens comprising the authorized documentnamespace identifier as a prefix and the each index token as a suffix,the completion token being a prefix of or matching the each index token;and for each prefixed index token of the plurality of prefixed indextokens, determining whether any documents identified in a postings listassociated with the each prefixed index token satisfies the completionquery, and returning filenames of any such documents satisfying thecompletion query in an answer to the completion query.
 20. Themulti-user computing system of claim 19, wherein the index dictionarycomprises index tokens extracted from filenames of documents belongingto a plurality of document namespaces.
 21. The multi-user computingsystem of claim 19, wherein the stop condition is reached after athreshold number of document filenames are returned in an answer to thecompletion query.
 22. The multi-user computing system of claim 19,wherein the stop condition is reached after expiration of a queryexecution timer.
 23. The multi-user computing system of claim 19,wherein the stop condition is reached after identifying and iteratingover a threshold number of index tokens of the plurality of indextokens.
 24. The multi-user computing system of claim 19, wherein thecompletion query comprises at least one complete token.